{include file="common/header"}
<div class="container-fluid buwei">
	{include file="common/history"}
	<div class="container person-center " style="width: 1200px;">
		<div class="person-center-left di-jianju">
			<h2 class="luntan-show-title">{$row.title}</h2>
			<p class="luntan-show-biaozhu"><span>浏览：{$row.hits}</span><span>发表于：{$row.createtime|date="Y-m-d H:i:s",###}</span> <span class="l con-l">作者：</span><span class="r con-l">{$row.users.username}</span>
				{eq name='$Think.session.medical_user.id' value='$row.user_id'}
				<a href="/index/bbs/editContent/ids/{$row.id}.html" class="con-r arti-edit">编辑</a>
				{/eq}
				<span class="r con-r">2018-07-12  11:23</span><span class="l con-r">修改时间：</span>
				<span class="r con-r">{$row.editnum}次</span><span class="l con-r">修改次数：</span>
			</p>
			<div class="luntan-con">{$row.content}</div>
			<div class="luntan-huifu">
				<h3 class="fuifu-num">共有{$row.reply_sum}条回复</h3>
				{foreach name="row.reply" item="vo"}
				<div class="luntan-huifu-list">
					<div class="huifu-list-left">
						<img src="__CDN__{$vo.users.avatar}">
					</div>
					<div class="huifu-list-center">
						<a href="javascript:;">{$vo.users.username}</a>
						<!-- nl2br -->
						<!-- $vo.content -->
						<a href=""><?php echo nl2br($vo['content']);?></a>
					</div>
					<div class="huifu-list-right">
						<p>{$vo.createtime|date="Y-m-d H:i:s",###}</p>
						<p>
							{eq name='vo.is_replyzan' value='0'}
							<span class="zan1 zan" data-id="{$vo.id}"><img src="__CDN__/assets/img/index/zan1.png">(<i style="font-style: normal;">{$vo.is_replyzan}</i>)</span>
							{else /}
							<span class="zan2 zan" data-id="{$vo.id}"><img src="__CDN__/assets/img/index/zan2.png">(<i style="font-style: normal;">{$vo.is_replyzan})</i></span>
							{/eq}
							<a id="shu">|</a>
							{eq name='vo.is_report' value='0'}
							<a href="javascript:;" onclick="report('{$vo.id}')">举报</a>
							{else /}
							<a href="javascript:;">已举报</a>
							{/eq}
						</p>
					</div>
					<div style="clear: both;"></div>
				</div>
				{/foreach}
			</div>
			{$pages}
			{notempty name="$Think.session.medical_user.id"}
			<form action="" method="POST" id="add-bbs-reply-form">
				<div class="fatieandedit-list">
					<div class="fatie-edit-left">
						<label>回复：</label>
					</div>
					<div class="fatie-edit-right editor" id="editfuihu">
						<input type="hidden" name="content_id" value="{$row.id}">
						<textarea style="width:850px;height:200px;resize:none;" name="content" placeholder="回复数字两百字以内"></textarea>
					</div>
				</div>

				<p class="di-biaozhu">请遵守智识医疗言论规则，不得违反国家法律法规</p>
				<input type="button" name="luntan-btn" id="add-bbs-reply" class="luntan-btn" value="发表回复">
			</form>
			{/notempty}


		</div>
		{include file="common/bbs/right"}
	</div>

</div>

<script type="text/javascript">
	$('.luntan-btn').click(function() {
		var reg = /^[^\~\`\!\@\#\$\%\^\&\*\(\)\-\_\+\=\{\}\[\]\|\\\;\:\'\"\,\.\<\>\/\?]{5,20}$/;
		var hf = $('#editfuihu').find('textarea').val().length;
		var hfs = $('#editfuihu').find('textarea').val();

		if(hf > 200 || (reg.exec(hfs)) || !hf) {
			return false;
		} else {
			return true;
		}
	})
</script>
{include file="common/login"}
{include file="common/footer"}